<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script>
        /**
        {"name":"David Niu"}
        {"age":"23"}
        {"gender":"男"}
         */
        var person = {
            name:"David Niu",
            age: 23,
            gender: "男",
            run:function (){
                console.log(this.name+" run...")
            }
        }
        var Bird = {
            fly:function (){
                console.log(this.name+" fly...")
            }
        }
        var xiaoming ={
            name: "xiaoming"
        }
        //xiaoming的原型时person
        //xiaoming.__proto__= person;
        xiaoming.__proto__= Bird;
        //对象转化为JSON
        var jsonuser = JSON.stringify(user);
        //JSON字符串转化为对象
        var obj = JSON.parse(jsonuser);
    </script>
</head>
<body>

</body>
</html>